Skip to content

Conversation

@martin4861
Copy link
Contributor

@martin4861 martin4861 commented Oct 23, 2025

Use the updated sysroots of swift-nav/swift-toolchains#27 for fixed symlinks.

Tested ✅

martin4861 added a commit to swift-nav/swift-toolchains that referenced this pull request Oct 27, 2025
I ran a comparison of the chromium's sysroots with ours and found out,
that symlinks look differently, e.g.
- chromium: `libutil.so -> ../../..//lib/x86_64-linux-gnu/libutil.so.1`
- ours (before this change): `libutil.so ->
/lib/x86_64-linux-gnu/libutil.so.1`

This might have worked in the past with Bazel 7, but with Bazel 8 in
some situations (maybe due to Bazel 8's stricter sandboxing) it just
fails. I was not able to reproduce it locally, it only happens in CI
with enabled Bazel Cache.

This change enables the relative symlink handling instead of using
absolute paths and syncs with the upstream script of the chromium
project.

(`lapack` and `blas` seem to be in the correct shape: `liblapack.a ->
./lapack/liblapack.a`)

Tested in swift-nav/rules_swiftnav#200 (see
testplan in PR description)
@martin4861 martin4861 force-pushed the martin4861/investigate-bazel8-x86_64-sysroots-linker-failures branch from cb138ac to 595c9f3 Compare October 27, 2025 12:17
@martin4861 martin4861 force-pushed the martin4861/investigate-bazel8-x86_64-sysroots-linker-failures branch from ce4af36 to a60a311 Compare October 27, 2025 12:24
@martin4861 martin4861 marked this pull request as ready for review October 27, 2025 12:44
@martin4861 martin4861 requested a review from a team as a code owner October 27, 2025 12:44
@martin4861 martin4861 requested a review from sbmueller October 27, 2025 12:44
@martin4861 martin4861 force-pushed the martin4861/investigate-bazel8-x86_64-sysroots-linker-failures branch 2 times, most recently from 0b401b0 to 8a7974d Compare October 27, 2025 15:04
@martin4861 martin4861 force-pushed the martin4861/investigate-bazel8-x86_64-sysroots-linker-failures branch from 8a7974d to b589be5 Compare October 27, 2025 15:07
Copy link
Contributor

@sbmueller sbmueller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome!

@martin4861 martin4861 merged commit 3d7491c into main Oct 27, 2025
2 checks passed
@martin4861 martin4861 deleted the martin4861/investigate-bazel8-x86_64-sysroots-linker-failures branch October 27, 2025 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants